package com.chw.api.menu;

import java.io.Serializable;
import java.util.Date;

import com.chw.utils.CommonFieldsUtil;

public class SysMenu implements Serializable {
	private static final long serialVersionUID = -5795244825376284428L;

	// 设置效验规则,主键字段不能为空
	private String id;

	private String createdBy;

	private Date createdDate;

	private String lastUpdatedBy;

	private Date lastUpdatedDate;

	private String enabledFlag;

	private String status;

	private String parentId;

	private String icon;

	private Integer level;

	private String name;

	private String url;

	private Integer seq;

	private String note;

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getCreatedBy() {
		return createdBy;
	}

	public void setCreatedBy(String createdBy) {
		this.createdBy = createdBy;
	}

	public Date getCreatedDate() {
		return createdDate;
	}

	public void setCreatedDate(Date createdDate) {
		this.createdDate = createdDate;
	}

	public String getLastUpdatedBy() {
		return lastUpdatedBy;
	}

	public void setLastUpdatedBy(String lastUpdatedBy) {
		this.lastUpdatedBy = lastUpdatedBy;
	}

	public Date getLastUpdatedDate() {
		return lastUpdatedDate;
	}

	public void setLastUpdatedDate(Date lastUpdatedDate) {
		this.lastUpdatedDate = lastUpdatedDate;
	}

	public String getEnabledFlag() {
		return enabledFlag;
	}

	public void setEnabledFlag(String enabledFlag) {
		this.enabledFlag = enabledFlag;
	}

	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getParentId() {
		return parentId;
	}

	public void setParentId(String parentId) {
		this.parentId = parentId;
	}

	public String getIcon() {
		return icon;
	}

	public void setIcon(String icon) {
		this.icon = icon;
	}

	public Integer getLevel() {
		return level;
	}

	public void setLevel(Integer level) {
		this.level = level;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public Integer getSeq() {
		return seq;
	}

	public void setSeq(Integer seq) {
		this.seq = seq;
	}

	public String getNote() {
		return note;
	}

	public void setNote(String note) {
		this.note = note;
	}

	public SysMenu initMenu() {
		SysMenu menu = new SysMenu();
		CommonFieldsUtil.setCreateValue(menu);
		menu.setName("测试菜单");
		menu.setId("/test/menu/url");
		return menu;
	}

	public String toString() {
		return new StringBuffer("\nSysMenu:id:").append(id).append("\ncreatedBy:").append(createdBy)
				.append("\ncreatedDate:").append(createdDate).append("\nlastUpdatedBy:").append(lastUpdatedBy)
				.append("\nlastUpdatedDate:").append(lastUpdatedDate).append("\nenabledFlag:").append(enabledFlag)
				.append("\nstatus:").append(status).toString();
	}
}